<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8" />
		<script src="https://cdn.bootcdn.net/ajax/libs/jquery/3.6.4/jquery.js"></script>
		<title></title>
		<style>
			* {
				cursor: pointer;
			}

			p {
				background-color: #bfa;
				padding: 5px;
				text-align: center;
			}
		</style>
	</head>

	<body>
		<p>If you click on me, I will disappear.</p>
		<script type="text/javascript">
			$(document).ready(function() {
				$("p").click(function() {
					$(this).hide();
				});
			});
		</script>
	</body>

</html>
